<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      var a = [2, 4, 7, 8, 565, 778, 8, 9, 0];
      var b = a.sort(function (value1, value2) {
        return value1 - value2;
      });
      console.log(b);


      console.log(Array.isArray(b));
    </script>
  </body>
</html>
